<?php

use yii\helpers\Html;

?>

<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <?= Html::jsFile('https://libs.baidu.com/jquery/2.0.0/jquery.min.js') ?>
    <?= Html::jsFile('js/bootstrap.min.js') ?>
    <?= Html::jsFile('@web/js/myAlert.js') ?>
    <?= Html::jsFile(' http://code.jquery.com/jquery-2.1.1.min.js') ?>
<!--    --><?//= Html::cssFile('@web/css/index/index.css') ?>

</head>
<body>
<div class="top">
    <div class="nav">

    </div>
</div>


<div class="xs">
    <div class="one">
        <input type="search" class="form-control" style="position: absolute;top: 7%;right: 17%;width: 50%;">
        <input type="submit" name="search" value="搜索" class="btn btn-success"
               style="position: absolute;top: 7%;right: 17%;width: 5%;">
    </div>
    <div style="margin-top: 20%;">
        <ul class="nav nav-tabs">
<!--            1-->
            <li role="presentation" class=" button1 active">
                <a href="#menu1" data-toggle="tab" class="active1">
                    <div id="noStart">秒杀未开始</div>
                    <div class="div1" id="startNow" style="display: none;">秒杀开始</div>
                    <div class="div2" id="stopNow" style="display: none;">秒杀结束</div>
                    <div class="none1">
                        <span class="content"></span>
                        <span class="botHours"></span>时
                        <span class="botMIn"></span>分
                        <span class="botSecond"></span>秒
                    </div>
                </a>
            </li>
            <li role="presentation" class="button2">
                <a href="#menu2" data-toggle="tab" class="active2">
                    <div id="noStart_one">秒杀未开始</div>
                    <div class="div1" id="startNow_one" style="display: none;">秒杀开始</div>
                    <div class="div2" id="stopNow_one" style="display: none;">秒杀结束</div>
                    <div class="none2">
                        <span class="content_one"></span>
                        <span class="botHours_one"></span>时
                        <span class="botMIn_one"></span>分
                        <span class="botSecond_one"></span>秒
                    </div>
                </a>
            </li>
             <li role="presentation" class="button3">
                 <a href="#menu3" data-toggle="tab" class="active3 active" >
                     <div id="noStart_two">秒杀未开始</div>
                     <div class="div1" id="startNow_two" style="display: none;">秒杀开始</div>
                     <div class="div2" id="stopNow_two" style="display: none;">秒杀结束</div>
                     <div class="none3">
                         <span class="content_two"></span>
                         <span class="botHours_two"></span>时
                         <span class="botMIn_two"></span>分
                         <span class="botSecond_two"></span>秒
                     </div>
                 </a>
             </li>
            <li role="presentation" class="button4">
                <a href="#menu4" data-toggle="tab" class="active4">
                    <div id="noStart_four">秒杀未开始</div>
                    <div class="div1" id="startNow_four" style="display: none;">秒杀开始</div>
                    <div class="div2" id="stopNow_four" style="display: none;">秒杀结束</div>
                    <div class="none4">
                        <span class="content_four"></span>
                        <span class="botHours_four"></span>时
                        <span class="botMIn_four"></span>分
                        <span class="botSecond_four"></span>秒
                    </div>
                </a>
            </li>
            <li role="presentation" class="button5">
                <a href="#menu5"  data-toggle="tab" class="active5">
                    <div id="noStart_five">秒杀未开始</div>
                    <div class="div1" id="startNow_five" style="display: none;">秒杀开始</div>
                    <div class="div2" id="stopNow_five" style="display: none;">秒杀结束</div>
                    <div class="none5">
                        <span class="content_five"></span>
                        <span class="botHours_five"></span>时
                        <span class="botMIn_five"></span>分
                        <span class="botSecond_five"></span>秒
                    </div>
                </a>
            </li>
        </ul>
        <div class="tab-content">

            <div id="menu1" class="container tab-pane active" style="border: 1px solid orangered;width: 100%;height:732px;">
                <div class="list-group" style="width: 25%;height: 350px;border: 1px solid #0a568c;float: left;margin-top: 1%;margin-left: 0%;">
                     <!--                       商品1-->
                    <!--                       商品1-->
                        <img src="<?php echo Yii::$app->redis->get('img');?>" width="100%" height="200px" alt="">
                    <span><?php echo Yii::$app->redis->get('id'); ?></span><br>
                    <span>￥<?php echo Yii::$app->redis->get('price'); ?></span><br>
                    <div style="float: left;margin-left:4%;">已售2%</div>
                    <div class="progress" style="border: 1px solid rebeccapurple;height: 10px;width: 60%;margin-left: 8%;margin-top: 2%;float: left;">
                        <div class="progress-bar" role="progressbar" aria-valuenow="2" aria-valuemin="0" aria-valuemax="100" style="min-width: 2em; width: 2%;">

                        </div>
                    </div>
                    <div style="clear: none"></div>
                    <button type="button" class="list-group-item" style="background-color: #00a7d0;width: 70%;margin-left: 16%;text-align: center;">立刻订购</button>
                </div>
                <div class="list-group" style="width: 24%;height: 350px;border: 1px solid #0a568c;float: left;margin-top: 1%;margin-left: 1%;">
                    <!--                       商品1-->
                    <button type="button" class="list-group-item">
                        <img src="https://img.alicdn.com/imgextra/i3/505700138/O1CN01rQRjM81CtFEpFArm2_!!0-saturn_solar.jpg_220x220.jpg_.webp" width="100%" height="200px" alt="">
                    </button>
                    <span>商品名称</span><br>
                    <span>商品价格</span>
                    <div class="progress">
                        <div class="progress-bar" role="progressbar" aria-valuenow="2" aria-valuemin="0" aria-valuemax="100" style="min-width: 2em; width: 2%;width: 20%;">
                            2%
                        </div>
                    </div>
                    <button type="button" class="list-group-item" style="background-color: #00a7d0;width: 70%;margin-left: 16%;text-align: center;">立刻订购</button>
                </div>
                <div class="list-group" style="width: 24%;height: 350px;border: 1px solid #0a568c;float: left;margin-top: 1%;margin-left: 1%;">
                    <!--                       商品1-->
                    <button type="button" class="list-group-item">
                        <img src="https://img.alicdn.com/imgextra/i3/505700138/O1CN01rQRjM81CtFEpFArm2_!!0-saturn_solar.jpg_220x220.jpg_.webp" width="100%" height="200px" alt="">
                    </button>
                    <span>商品名称</span><br>
                    <span>商品价格</span>
                    <div class="progress">
                        <div class="progress-bar" role="progressbar" aria-valuenow="2" aria-valuemin="0" aria-valuemax="100" style="min-width: 2em; width: 2%;width: 20%;">
                            2%
                        </div>
                    </div>
                    <button type="button" class="list-group-item" style="background-color: #00a7d0;width: 70%;margin-left: 16%;text-align: center;">立刻订购</button>
                </div>
                <div class="list-group" style="width: 24%;height: 350px;border: 1px solid #0a568c;float: left;margin-top: 1%;margin-left: 1%;">
                    <!--                       商品1-->
                    <button type="button" class="list-group-item">
                        <img src="https://img.alicdn.com/imgextra/i3/505700138/O1CN01rQRjM81CtFEpFArm2_!!0-saturn_solar.jpg_220x220.jpg_.webp" width="100%" height="200px" alt="">
                    </button>
                    <span>商品名称</span><br>
                    <span>商品价格</span>
                    <div class="progress">
                        <div class="progress-bar" role="progressbar" aria-valuenow="2" aria-valuemin="0" aria-valuemax="100" style="min-width: 2em; width: 2%;width: 20%;">
                            2%
                        </div>
                    </div>
                    <button type="button" class="list-group-item" style="background-color: #00a7d0;width: 70%;margin-left: 16%;text-align: center;">立刻订购</button>
                </div>
<!--                   第二行-->
                <div class="list-group" style="width: 25%;height: 350px;border: 1px solid #0a568c;float: left;margin-top: -1%;margin-left: 0%;">

                    <!--                       商品1-->

                    <!--                       商品1-->


                    <img src="https://img11.360buyimg.com/mobilecms/s250x250_jfs/t1/84801/18/8195/136267/5e01bc91E5267aed6/f47fa46d2642f506.jpg" width="100%" height="200px" alt="">

                    <span>商品名称</span><br>
                    <span>商品价格</span><br>
                    <div style="float: left;margin-left:4%;">已售2%</div>
                    <div class="progress" style="border: 1px solid rebeccapurple;height: 10px;width: 60%;margin-left: 8%;margin-top: 2%;float: left;">
                        <div class="progress-bar" role="progressbar" aria-valuenow="2" aria-valuemin="0" aria-valuemax="100" style="min-width: 2em; width: 2%;">

                        </div>
                    </div>
                    <div style="clear: none"></div>
                    <button type="button" class="list-group-item" style="background-color: #00a7d0;width: 70%;margin-left: 16%;text-align: center;">立刻订购</button>
                </div>
                <div class="list-group" style="width: 24%;height: 350px;border: 1px solid #0a568c;float: left;margin-top: -1%;margin-left: 1%;">
                    <!--                       商品1-->
                    <button type="button" class="list-group-item">
                        <img src="https://img.alicdn.com/imgextra/i3/505700138/O1CN01rQRjM81CtFEpFArm2_!!0-saturn_solar.jpg_220x220.jpg_.webp" width="100%" height="200px" alt="">
                    </button>
                    <span>商品名称</span><br>
                    <span>商品价格</span>
                    <div class="progress">
                        <div class="progress-bar" role="progressbar" aria-valuenow="2" aria-valuemin="0" aria-valuemax="100" style="min-width: 2em; width: 2%;width: 20%;">
                            2%
                        </div>
                    </div>
                    <button type="button" class="list-group-item" style="background-color: #00a7d0;width: 70%;margin-left: 16%;text-align: center;">立刻订购</button>
                </div>
                <div class="list-group" style="width: 24%;height: 350px;border: 1px solid #0a568c;float: left;margin-top: -1%;margin-left: 1%;">
                    <!--                       商品1-->
                    <button type="button" class="list-group-item">
                        <img src="https://img.alicdn.com/imgextra/i3/505700138/O1CN01rQRjM81CtFEpFArm2_!!0-saturn_solar.jpg_220x220.jpg_.webp" width="100%" height="200px" alt="">
                    </button>
                    <span>商品名称</span><br>
                    <span>商品价格</span>
                    <div class="progress">
                        <div class="progress-bar" role="progressbar" aria-valuenow="2" aria-valuemin="0" aria-valuemax="100" style="min-width: 2em; width: 2%;width: 20%;">
                            2%
                        </div>
                    </div>
                    <button type="button" class="list-group-item" style="background-color: #00a7d0;width: 70%;margin-left: 16%;text-align: center;">立刻订购</button>
                </div>
                <div class="list-group" style="width: 24%;height: 350px;border: 1px solid #0a568c;float: left;margin-top: -1%;margin-left: 1%;">
                    <!--                       商品1-->
                    <button type="button" class="list-group-item">
                        <img src="https://img.alicdn.com/imgextra/i3/505700138/O1CN01rQRjM81CtFEpFArm2_!!0-saturn_solar.jpg_220x220.jpg_.webp" width="100%" height="200px" alt="">
                    </button>
                    <span>商品名称</span><br>
                    <span>商品价格</span>
                    <div class="progress">
                        <div class="progress-bar" role="progressbar" aria-valuenow="2" aria-valuemin="0" aria-valuemax="100" style="min-width: 2em; width: 2%;width: 20%;">
                            2%
                        </div>
                    </div>
                    <button type="button" class="list-group-item" style="background-color: #00a7d0;width: 70%;margin-left: 16%;text-align: center;">立刻订购</button>
                </div>
                <!--                   第二行-->
            </div>

            <div id="menu2" class="container tab-pane">123</div>
            <div id="menu3" class="container tab-pane fade">
                33
            </div>
            <div id="menu4"  class="container tab-pane fade">
                44
            </div>
            <div id="menu5" class="container tab-pane fade">
                55
            </div>




</div>
</body>
</html>
<!--10:00到12：00-->
<script>
    $(function () {
        fn()

        function fn() {
            var timer = setInterval(function () {
                var start = ';2019/03/14 00:00:00'
                var StartTime = new Date(start);
                var NowTime = new Date();
                var day = NowTime.getDate();
                var month = NowTime.getMonth() + 1;
                var year = NowTime.getFullYear();
                var tw = year + '/' + month + '/' + day + ' 8:00:00';
                var ei = year + '/' + month + '/' + day + ' 9:52:00';
                // var tw1 = year + '/' + month + '/' + day + ' 14:00:00';
                // var ei1 = year + '/' + month + '/' + day + ' 12:00:00';
                tw = new Date(tw).getTime();
                ei = new Date(ei).getTime();
                // tw1 = new Date(tw1).getTime();
                // ei1 = new Date(ei1).getTime();
                var EndTime = '';
                if (NowTime < StartTime) {
                    EndTime = StartTime;
                    $('#stopNow').css('display', 'none');
                    $('#startNow').css('display', 'none');
                    $('#noStart').css('display', 'block');
                    $(".content").html("距离秒杀开始")
                } else {
                    if (NowTime < tw) {
                        EndTime = tw;
                        $('#stopNow').css('display', 'none');
                        $('#startNow').css('display', 'none');
                        $('#noStart').css('display', 'block');
                        $(".content").html("距离秒杀开始剩余")
                    } else if (NowTime >= tw && NowTime < ei) {
                        EndTime = ei;
                        $(".none1").css('display','block');
                        $('#stopNow').css('display', 'none');
                        $('#startNow').css('display', 'block');
                        $('#noStart').css('display', 'none');
                        $(".content").html("距离活动结束剩余")
                    }
                    // else if (NowTime < tw1) {
                    //     EndTime = tw1;
                    //     $('#stopNow').css('display', 'none');
                    //     $('#startNow').css('display', 'none');
                    //     $('#noStart').css('display', 'block');
                    //     $(".content").html("距离秒杀开始剩余")
                    // } else if (NowTime >= tw1 && NowTime < ei1) {
                    //     EndTime = ei1;
                    //     $('#stopNow').css('display', 'none');
                    //     $('#startNow').css('display', 'block');
                    //     $('#noStart').css('display', 'none');
                    //     $(".content").html("距离活动结束剩余")
                    // } else if (NowTime >= ei1) {
                    //     EndTime = tw + 24 * 60 * 60 * 1000;
                    //     $('#stopNow').css('display', 'block');
                    //     $('#startNow').css('display', 'none');
                    //     $('#noStart').css('display', 'none');
                    //     $(".content").html("距离活动开始剩余")
                    // }
                }
                console.log(EndTime)
                var t = EndTime - NowTime;
                if (t < 1000) {
                    // window.location.reload();
                     $("#menu1").css('display','none');
                     $(".button1").css('display','none');
                    $(".active2").trigger("click");
                    clearInterval(timer);
                    timer = null;
                    return false;
                    die();
                }
                var d = 0;
                var h = 0;
                var m = 0;
                var s = 0;
                if (t >= 0) {
                    d = Math.floor((t / 1000 / 3600) / 24);
                    h = Math.floor((t / 1000 / 3600) % 24);
                    m = Math.floor((t / 1000 / 60) % 60);
                    s = Math.floor(t / 1000 % 60);
                    if (d < 10) {
                        d = "0" + d;
                    }
                    if (h < 10) {
                        h = "0" + h;
                    }
                    if (m < 10) {
                        m = "0" + m;
                    }
                    if (s < 10) {
                        s = "0" + s;
                    }
                    $('.botHours').html(h);
                    $('.botMIn').html(m);
                    $('.botSecond').html(s);
                }
            }, 1000)
        }
    });

</script>

<!--12:00到14：00-->
<script >
    $(function () {
        fn()

        function fn() {
            var timer = setInterval(function () {
                var start = ';2019/03/14 00:00:00'
                var StartTime = new Date(start);
                var NowTime = new Date();
                var day = NowTime.getDate();
                var month = NowTime.getMonth() + 1;
                var year = NowTime.getFullYear();
                var tw = year + '/' + month + '/' + day + ' 12:00:00';
                var ei = year + '/' + month + '/' + day + ' 14:00:00';
                // var tw1 = year + '/' + month + '/' + day + ' 12:00:00';
                // var ei1 = year + '/' + month + '/' + day + ' 14:39:00';
                tw = new Date(tw).getTime();
                ei = new Date(ei).getTime();
                // tw1 = new Date(tw1).getTime();
                // ei1 = new Date(ei1).getTime();
                var EndTime = '';
                if (NowTime < StartTime) {
                    EndTime = StartTime;
                    $('#stopNow_one').css('display', 'none');
                    $('#startNow_one').css('display', 'none');
                    $('#noStart_one').css('display', 'block');
                    $(".content_one").html("距离秒杀开始")
                } else {
                    if (NowTime < tw) {
                        EndTime = tw;
                        $(".none2").css('display','none');
                        $('#stopNow_one').css('display', 'none');
                        $('#startNow_one').css('display', 'none');
                        $('#noStart_one').css('display', 'block');
                        $(".content_one").html("距离秒杀开始剩余")
                    } else if (NowTime >= tw && NowTime < ei) {
                        EndTime = ei;
                        $(".none2").css('display','block');
                        $('#stopNow_one').css('display', 'none');
                        $('#startNow_one').css('display', 'block');
                        $('#noStart_one').css('display', 'none');
                        $(".content_one").html("距离活动结束剩余")
                    }
                    // else if (NowTime < tw1) {
                    //     EndTime = tw1;
                    //     $('#stopNow_one').css('display', 'none');
                    //     $('#startNow_one').css('display', 'none');
                    //     $('#noStart_one').css('display', 'block');
                    //     $(".content_one").html("距离秒杀开始剩余")
                    // } else if (NowTime >= tw1 && NowTime < ei1) {
                    //     EndTime = ei1;
                    //     $('#stopNow_one').css('display', 'none');
                    //     $('#startNow_one').css('display', 'block');
                    //     $('#noStart_one').css('display', 'none');
                    //     $(".content_one").html("距离活动结束剩余")
                    // } else if (NowTime >= ei1) {
                    //     EndTime = tw + 24 * 60 * 60 * 1000;
                    //     $('#stopNow_one').css('display', 'block');
                    //     $('#startNow_one').css('display', 'none');
                    //     $('#noStart_one').css('display', 'none');
                    //     $(".content_one").html("距离活动开始剩余")
                    // }
                }
                console.log(EndTime)
                var t = EndTime - NowTime;
                if (t < 1000) {
                    // window.location.reload();
                    $("#menu2").css('display','none');
                    $(".button2").css('display','none');
                    $(".active3").trigger("click");
                    clearInterval(timer);
                    timer = null;
                    return false;
                }
                var d = 0;
                var h = 0;
                var m = 0;
                var s = 0;
                if (t >= 0) {
                    d = Math.floor((t / 1000 / 3600) / 24);
                    h = Math.floor((t / 1000 / 3600) % 24);
                    m = Math.floor((t / 1000 / 60) % 60);
                    s = Math.floor(t / 1000 % 60);
                    if (d < 10) {
                        d = "0" + d;
                    }
                    if (h < 10) {
                        h = "0" + h;
                    }
                    if (m < 10) {
                        m = "0" + m;
                    }
                    if (s < 10) {
                        s = "0" + s;
                    }
                    $('.botHours_one').html(h);
                    $('.botMIn_one').html(m);
                    $('.botSecond_one').html(s);
                }
            }, 1000)
        }
    });

</script>
<!--14:00到16：00-->
<script>
    $(function () {
        fn()

        function fn() {
            var timer = setInterval(function () {
                var start = ';2019/03/14 00:00:00'
                var StartTime = new Date(start);
                var NowTime = new Date();
                var day = NowTime.getDate();
                var month = NowTime.getMonth() + 1;
                var year = NowTime.getFullYear();
                var tw = year + '/' + month + '/' + day + ' 14:00:00';
                var ei = year + '/' + month + '/' + day + ' 16:00:00';
                // var tw1 = year + '/' + month + '/' + day + ' 14:39:00';
                // var ei1 = year + '/' + month + '/' + day + ' 16:00:00';
                tw = new Date(tw).getTime();
                ei = new Date(ei).getTime();
                // tw1 = new Date(tw1).getTime();
                // ei1 = new Date(ei1).getTime();
                var EndTime = '';
                if (NowTime < StartTime) {
                    EndTime = StartTime;
                    $('#stopNow_two').css('display', 'none');
                    $('#startNow_two').css('display', 'none');
                    $('#noStart_two').css('display', 'block');
                    $(".content_two").html("距离秒杀开始")
                } else {
                    if (NowTime < tw) {
                        EndTime = tw;
                        $(".none3").css('display','none');
                        $('#stopNow_two').css('display', 'none');
                        $('#startNow_two').css('display', 'none');
                        $('#noStart_two').css('display', 'block');
                        $(".content_two").html("距离秒杀开始剩余")
                    } else if (NowTime >= tw && NowTime < ei) {
                        EndTime = ei;
                        $(".none3").css('display','block');
                        $('#stopNow_two').css('display', 'none');
                        $('#startNow_two').css('display', 'block');
                        $('#noStart_two').css('display', 'none');
                        $(".content_two").html("距离活动结束剩余")
                    }
                    // else if (NowTime < tw1) {
                    //     EndTime = tw1;
                    //     $('#stopNow_two').css('display', 'none');
                    //     $('#startNow_two').css('display', 'none');
                    //     $('#noStart_two').css('display', 'block');
                    //     $(".content_two").html("距离秒杀开始剩余")
                    // } else if (NowTime >= tw1 && NowTime < ei1) {
                    //     EndTime = ei1;
                    //     $('#stopNow_two').css('display', 'none');
                    //     $('#startNow_two').css('display', 'block');
                    //     $('#noStart_two').css('display', 'none');
                    //     $(".content_two").html("距离活动结束剩余")
                    // } else if (NowTime >= ei1) {
                    //     EndTime = tw + 24 * 60 * 60 * 1000;
                    //     $('#stopNow_two').css('display', 'block');
                    //     $('#startNow_two').css('display', 'none');
                    //     $('#noStart_two').css('display', 'none');
                    //     $(".content_two").html("距离活动开始剩余")
                    // }
                }
                console.log(EndTime)
                var t = EndTime - NowTime;
                if (t < 1000) {
                    $("#menu3").css('display','none');
                    $(".button3").css('display','none');
                    $(".active4").trigger("click");
                    clearInterval(timer);
                    timer = null;
                    return false;
                }
                var d = 0;
                var h = 0;
                var m = 0;
                var s = 0;
                if (t >= 0) {
                    d = Math.floor((t / 1000 / 3600) / 24);
                    h = Math.floor((t / 1000 / 3600) % 24);
                    m = Math.floor((t / 1000 / 60) % 60);
                    s = Math.floor(t / 1000 % 60);
                    if (d < 10) {
                        d = "0" + d;
                    }
                    if (h < 10) {
                        h = "0" + h;
                    }
                    if (m < 10) {
                        m = "0" + m;
                    }
                    if (s < 10) {
                        s = "0" + s;
                    }
                    $('.botHours_two').html(h);
                    $('.botMIn_two').html(m);
                    $('.botSecond_two').html(s);
                }
            }, 1000)
        }
    });

</script>
<!--19:00到20：00-->
<script>
    $(function () {
        fn()

        function fn() {
            var timer = setInterval(function () {
                var start = ';2019/03/14 00:00:00'
                var StartTime = new Date(start);
                var NowTime = new Date();
                var day = NowTime.getDate();
                var month = NowTime.getMonth() + 1;
                var year = NowTime.getFullYear();
                var tw = year + '/' + month + '/' + day + ' 20:30:00';
                var ei = year + '/' + month + '/' + day + ' 21:00:00';
                // var tw1 = year + '/' + month + '/' + day + ' 16:00:00';
                // var ei1 = year + '/' + month + '/' + day + ' 18:00:00';
                tw = new Date(tw).getTime();
                ei = new Date(ei).getTime();
                // tw1 = new Date(tw1).getTime();
                // ei1 = new Date(ei1).getTime();
                var EndTime = '';
                if (NowTime < StartTime) {
                    EndTime = StartTime;
                    $('#stopNow_four').css('display', 'none');
                    $('#startNow_four').css('display', 'none');
                    $('#noStart_four').css('display', 'block');
                    $(".content_four").html("距离秒杀开始")
                } else {
                    if (NowTime < tw) {
                        EndTime = tw;
                        $(".none4").css('display','none');
                        $('#stopNow_four').css('display', 'none');
                        $('#startNow_four').css('display', 'none');
                        $('#noStart_four').css('display', 'block');
                        $(".content_four").html("距离秒杀开始剩余")
                    } else if (NowTime >= tw && NowTime < ei) {
                        EndTime = ei;
                        $(".none4").css('display','block');
                        $('#stopNow_four').css('display', 'none');
                        $('#startNow_four').css('display', 'block');
                        $('#noStart_four').css('display', 'none');
                        $(".content_four").html("距离活动结束剩余")
                    }
                    // else if (NowTime < tw1) {
                    //     EndTime = tw1;
                    //     $('#stopNow_three').css('display', 'none');
                    //     $('#startNow_three').css('display', 'none');
                    //     $('#noStart_three').css('display', 'block');
                    //     $(".content_three").html("距离秒杀开始剩余")
                    // } else if (NowTime >= tw1 && NowTime < ei1) {
                    //     EndTime = ei1;
                    //     $('#stopNow_three').css('display', 'none');
                    //     $('#startNow_three').css('display', 'block');
                    //     $('#noStart_three').css('display', 'none');
                    //     $(".content_three").html("距离活动结束剩余")
                    // } else if (NowTime >= ei1) {
                    //     EndTime = tw + 24 * 60 * 60 * 1000;
                    //     $('#stopNow_three').css('display', 'block');
                    //     $('#startNow_three').css('display', 'none');
                    //     $('#noStart_three').css('display', 'none');
                    //     $(".content_three").html("距离活动开始剩余")
                    // }
                }
                console.log(EndTime)
                var t = EndTime - NowTime;
                if (t < 1000) {
                    // window.location.reload();
                    $("#menu4").css('display','none');
                    $(".button4").css('display','none');
                    $(".active5").trigger("click");

                    clearInterval(timer);
                    timer = null;
                    return false;
                }
                var d = 0;
                var h = 0;
                var m = 0;
                var s = 0;
                if (t >= 0) {
                    d = Math.floor((t / 1000 / 3600) / 24);
                    h = Math.floor((t / 1000 / 3600) % 24);
                    m = Math.floor((t / 1000 / 60) % 60);
                    s = Math.floor(t / 1000 % 60);
                    if (d < 10) {
                        d = "0" + d;
                    }
                    if (h < 10) {
                        h = "0" + h;
                    }
                    if (m < 10) {
                        m = "0" + m;
                    }
                    if (s < 10) {
                        s = "0" + s;
                    }
                    $('.botHours_four').html(h);
                    $('.botMIn_four').html(m);
                    $('.botSecond_four').html(s);
                }
            }, 1000)
        }
    });

</script>
<!--20:00到21：00-->
<script>
    $(function () {
        fn()

        function fn() {
            var timer = setInterval(function () {
                var start = ';2019/03/14 00:00:00'
                var StartTime = new Date(start);
                var NowTime = new Date();
                var day = NowTime.getDate();
                var month = NowTime.getMonth() + 1;
                var year = NowTime.getFullYear();
                var tw = year + '/' + month + '/' + day + ' 21:00:00';
                var ei = year + '/' + month + '/' + day + ' 21:20:00';
                // var tw1 = year + '/' + month + '/' + day + ' 18:00:00';
                // var ei1 = year + '/' + month + '/' + day + ' 20:00:00';
                tw = new Date(tw).getTime();
                ei = new Date(ei).getTime();
                // tw1 = new Date(tw1).getTime();
                // ei1 = new Date(ei1).getTime();
                var EndTime = '';
                if (NowTime < StartTime) {
                    EndTime = StartTime;
                    $('#stopNow_five').css('display', 'none');
                    $('#startNow_five').css('display', 'none');
                    $('#noStart_five').css('display', 'block');
                    $(".content_five").html("距离秒杀开始")
                } else {
                    if (NowTime < tw) {
                        EndTime = tw;
                        $(".none5").css('display','none');
                        $('#stopNow_five').css('display', 'none');
                        $('#startNow_five').css('display', 'none');
                        $('#noStart_five').css('display', 'block');
                        $(".content_five").html("距离秒杀开始剩余")
                    } else if (NowTime >= tw && NowTime < ei) {
                        EndTime = ei;
                        $(".none5").css('display','block');
                        $('#stopNow_five').css('display', 'none');
                        $('#startNow_five').css('display', 'block');
                        $('#noStart_five').css('display', 'none');
                        $(".content_five").html("距离活动结束剩余")
                    }
                    // else if (NowTime < tw1) {
                    //     EndTime = tw1;
                    //     $('#stopNow_four').css('display', 'none');
                    //     $('#startNow_four').css('display', 'none');
                    //     $('#noStart_four').css('display', 'block');
                    //     $(".content_four").html("距离秒杀开始剩余")
                    // } else if (NowTime >= tw1 && NowTime < ei1) {
                    //     EndTime = ei1;
                    //     $('#stopNow_four').css('display', 'none');
                    //     $('#startNow_four').css('display', 'block');
                    //     $('#noStart_four').css('display', 'none');
                    //     $(".content_four").html("距离活动结束剩余")
                    // } else if (NowTime >= ei1) {
                    //     EndTime = tw + 24 * 60 * 60 * 1000;
                    //     $('#stopNow_four').css('display', 'block');
                    //     $('#startNow_four').css('display', 'none');
                    //     $('#noStart_four').css('display', 'none');
                    //     $(".content_four").html("距离活动开始剩余")
                    // }
                }
                console.log(EndTime)
                var t = EndTime - NowTime;
                if (t < 1000) {
                    // window.location.reload();
                    $("#menu5").css('display','none');
                    $(".button5").css('display','none');
                    clearInterval(timer);
                    timer = null;
                    return false;
                }
                var d = 0;
                var h = 0;
                var m = 0;
                var s = 0;
                if (t >= 0) {
                    d = Math.floor((t / 1000 / 3600) / 24);
                    h = Math.floor((t / 1000 / 3600) % 24);
                    m = Math.floor((t / 1000 / 60) % 60);
                    s = Math.floor(t / 1000 % 60);
                    if (d < 10) {
                        d = "0" + d;
                    }
                    if (h < 10) {
                        h = "0" + h;
                    }
                    if (m < 10) {
                        m = "0" + m;
                    }
                    if (s < 10) {
                        s = "0" + s;
                    }
                    $('.botHours_five').html(h);
                    $('.botMIn_five').html(m);
                    $('.botSecond_five').html(s);
                }
            }, 1000)
        }
    });

</script>
<!--点击menu事件-->
<script>
      $(".none1").click(function () {
            $(".none1").css('display','block');
            $(".none2").css('display','none');
            $(".none3").css('display','none');
            $(".none4").css('display','none');
            $(".none5").css('display','none');
      })
      $(".none2").click(function () {
            $(".none1").css('display','none');
            $(".none2").css('display','block');
            $(".none3").css('display','none');
            $(".none4").css('display','none');
            $(".none5").css('display','block');
      })
      $(".active3").click(function () {
            $(".none1").css('display','none');
            $(".none2").css('display','none');
            $(".none3").css('display','block');
            $(".none4").css('display','none');
            $(".none5").css('display','none');
      })
      $(".active4").click(function () {
            $(".none1").css('display','none');
            $(".none2").css('display','none');
            $(".none3").css('display','none');
            $(".none4").css('display','block');
            $(".none5").css('display','none');
      })
      $(".active5").click(function () {
            $(".none1").css('display','none');
            $(".none2").css('display','none');
            $(".none3").css('display','none');
            $(".none4").css('display','none');
            $(".none5").css('display','block');
      })
</script>